package clientejws;

import ejb.CalculadoraRemote;
import javax.ejb.EJB;
import javax.swing.JFrame;
import javax.swing.WindowConstants;

public class Main {
    @EJB
    private static CalculadoraRemote calculadora;

    public static void main(String[] args) {
        JFrame ventana = new JFrame();
        ventana.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
        ventana.setVisible(true);
        
        try {
            ventana.setTitle("" + calculadora.sumar(1, 6));
        } catch (Exception e) {
            ventana.setTitle(e.toString());
        }
        
    }
}
